<?php
/*
 * @ https://EasyToYou.eu - IonCube v11 Decoder Online
 * @ PHP 7.2 & 7.3
 * @ Decoder version: 1.1.6
 * @ Release: 10/08/2022
 */

// Decoded file for php version 71.
namespace longbingcore\tools;

class LongbingArr
{
    public static function delBykey($arr, $key)
    {
        if(is_array($key)) {
            foreach ($key as $k => $v) {
                $arr = self::delBykey($arr, $v);
            }
            return $arr;
        } else {
            if(!array_key_exists($key, $arr)) {
                return $arr;
            }
            $keys = array_keys($arr);
            $index = array_search($key, $keys);
            if($index !== false) {
                array_splice($arr, $index, 1);
            }
            return $arr;
        }
    }
    public static function unique_multidim_array($array, $key)
    {
        $temp_array = [];
        $i = 0;
        $key_array = [];
        foreach ($array as $val) {
            if(!in_array($val[$key], $key_array)) {
                $key_array[$i] = $val[$key];
                $temp_array[$i] = $val;
            }
            $i++;
        }
        return $temp_array;
    }
    public static function array_merge($array)
    {
        $returnArr = [];
        foreach ($array as $item) {
            if(!empty($item)) {
                $returnArr = array_merge($returnArr, $item);
            }
        }
        return $returnArr;
    }
}

?>